#pragma once
#include <windows.h>

class CPUMeasure
{
public:
	CPUMeasure(void);
public:
	~CPUMeasure(void);
	void Measure();
	bool bEnd;
	char chCPUHistory;
protected:
	HANDLE hIdleThread;
	
	bool ThreadCreate(void);
	static DWORD idleThread(LPVOID lpParameter);
	DWORD GetThreadTick(FILETIME* a, FILETIME* b);
	void KillThread();
private:
	DWORD	dwLastThreadTime;
	DWORD	dwLastTickTime;
};
